<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
<%@ taglib uri="http://www.springframework.org/tags/form" prefix="form" %>
<%@ include file="../general/header.jsp" %>
<script type="text/javascript">$($.date_input.initialize);</script>
		<h3>B&uacute;squeda</h3>		
		<div class="menuacciones">
			<button class="boton" onclick="return showPopup('popupcargar');" />Cargar</button>
			<button class="boton" onclick="return showPopup('popupguardar');" />Guardar</button> 
			<a class="boton" href="../search/Search">Resetear</a>
		</div>
		<div class="featurebox_center" id="search" >
			<form:form method="POST" class="form" action="../search/SearchUtil" commandName="SearchForm">
				<div class="popup popupguardar">
					<p>Ingrese un nombre para la b&uacute;squeda</p>
					<form:input type="text" path="savedSearchName" />
					<input class="boton" type="submit" name="saveSearch" value="Guardar B&uacute;squeda" />
				</div>			
				<div class="popup popupcargar">
					<p>Cargar una b&uacute;squeda guardada: </p>
					<select name="choose" size="1" >
					  	<option value="" >Seleccione una b&uacute;squeda</option>
						<c:forEach items="${savedSearches}" var="savedSearch" >  
							<option value="${savedSearch.id}" >${savedSearch.savedSearchName}</option>  
						</c:forEach>  
					</select>
					<input class="boton" type="submit" name="loadSearch" value="Cargar" />
				</div>			
				<form:errors path="savedSearchName" />
				<div class="form-field">
					<label>Palabras clave: </label>
					<form:input type="text" path="keywords" />
				</div>
				<div class="form-field">
					<label>Nombre: </label>
					<form:input class="valid" type="text" path="name" />
				</div>
				<div class="form-field">
					<label>Apellido: </label>
					<form:input type="text" path="lastname" />
				</div>
				<div class="form-field">
					<label>N&uacute;mero de documento: </label>
					<form:input type="text" path="docnumber" />
				</div>
				<div class="form-field">
					<label>E-mail: </label>
					<form:input type="text" path="email" />
				</div>
				<div class="form-field">
					<label>Educaci&oacute;n (universidad, etc): </label>
					<form:input type="text" path="education" />
				</div>
				<div class="form-field">
					<label>T&iacute;tulo de carrera: </label>
					<form:input type="text" path="title" />
				</div>
				<div class="form-field">
					<label>Trabajo (actual o pasado): </label>
					<form:input type="text" path="job" />
				</div>
				<div class="form-field labeled-checkbox"> 
					<form:checkbox path="searchLinkedin" label="Buscar en LinkedIn" checked="checked"/>
				</div>
				<div class="form-field labeled-checkbox"> 
					<form:checkbox path="searchFacebook" label="Buscar en Facebook" checked="checked"/>
				</div>
				<div class="menuacciones-center">
					<input class="boton" type="submit" name="search" style="width:200px;" value="Buscar" /> 
				</div>
			</form:form>
			
		</div>
	<%@ include file="../general/footer.jsp" %>